import { Post } from '@/api/http.js';
const isLocal = import.meta.env.VITE_NODE_ENV === 'local';
import loginJSON from '@/mock/login.json';

// 登录接口
export const user = (data) => (isLocal ? loginJSON : Post('/user/login', data));

// 获取验证码
export const sendSms = (data) => Post('/user/sendSms', data);

// 注册
export const register = (data) => Post('/user/register', data);

// 重置密码
export const resetPassword = (data) => Post('/user/resetPassword', data);
